package com.pwt.repository;

import com.pwt.repository.base.BaseRepository;
import com.pwt.entity.WhatLineHierarchy;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * WhatLineHierarchy Repository层
 *
 * @author auto generated
 * @date 2022-02-11 17:22:03
 */
public interface WhatLineHierarchyRepository extends BaseRepository<WhatLineHierarchy, String> {

    public void deleteByWhatLineId(String id);

    @Query(nativeQuery = true,value = "select  hierarchyId from what_line_hierarchy where whatLineId=?1")
    List<String> queryHierarchyByWhatLineId(String whatLineId);


}
